package com.heima.stroke.handler.valuation;

public class BasicValuation implements Valuation {
    private Valuation valuation;

    public BasicValuation(Valuation valuation){
        this.valuation = valuation;
    }

    @Override
    public float calculation(float km) {
        //判断当前是否大于3km
        if (km > 3){
            return (float) ((km-3)*2.3);
        }
        return 0;
    }
}
